//公司电话（comTel）、公司性质类型(comType)和公司地址(comAddress)
class IconDetailBean{
  String? loanAmount='';
  String? loanPeriod='';
  String? gpsCityName='';
  String? provinceId='';
  String? cityId='';
  String? locationGps;
  String? dwellAddress=''; //居住地址
  String? credit='';
  String? jddept='';
  String propertyItems='';
  String? profession='';
  String? job='';//工作单位不能为空
  String? marriage='';
  String? education='';
  String? loanPurpose='';
  String? houseType ='';
  String? name;
  String? age='';
  String? monthIncome='';
  String? idCard;
  String? comTel='';
  String? comType='';
  String? comAddress='';

  List<CommonLiaison>? commonLiaison;
  List<UrgentLiaison>? urgentLiaison;
  //进件信息时step=1，联系人信息时step=2
  int? step;
  Map<String, dynamic> toJson() {
    final map = <String, dynamic>{};
    map['loanAmount'] = loanAmount;
    map['loanPeriod'] = loanPeriod;
    map['gpsCityName'] = gpsCityName;
    map['provinceId'] = provinceId;
    map['cityId'] = cityId;
    map['dwellAddress'] = dwellAddress;
    map['credit'] = credit;
    map['jddept'] = jddept;
    map['propertyItems'] = propertyItems;
    map['profession'] = profession;
    map['job'] = job;
    map['marriage'] = marriage;
    map['education'] = education;
    map['loanPurpose'] = loanPurpose;
    map['houseType'] = houseType;
    map['step'] = step;
    map['name'] = name;
    map['age'] = age;
    map['idCard'] = idCard;
    map['gps'] = locationGps;
    map['monthIncome'] = monthIncome;
    map['comTel'] = comTel;
    map['comType'] = comType;
    map['comAddress'] = comAddress;



    // if (locationGps != null) {
    //   map['gps'] = locationGps?.toJson();
    // }
    if (commonLiaison != null) {
      map['commonLiaison'] = commonLiaison?.map((v) => v.toJson()).toList();
    }
    if (urgentLiaison != null) {
      map['urgentLiaison'] = urgentLiaison?.map((v) => v.toJson()).toList();
    }
    return map;
  }
}

class UrgentLiaison {
  String? name;
  String? mobile;
  String? contact;
  int? isCommon;

  UrgentLiaison(this.name, this.mobile, this.contact,this.isCommon);

  Map<String, dynamic> toJson() {
    final map = <String, dynamic>{};
    map['name'] = name;
    map['mobile'] = mobile;
    map['contact'] = contact;
    map['isCommon'] = isCommon;
    return map;
  }
}

class CommonLiaison {
  String? name;
  String? mobile;
  String? contact;
  int? isCommon;

  CommonLiaison(this.name, this.mobile, this.contact,this.isCommon);

  Map<String, dynamic> toJson() {
    final map = <String, dynamic>{};
    map['name'] = name;
    map['mobile'] = mobile;
    map['contact'] = contact;
    map['isCommon'] = isCommon;
    return map;
  }
}

class gps {
  String? province;
  String? city;


  @override
  String toString() {
    return '{province: $province, city: $city}';
  }

  Map<String, dynamic> toJson() {
    final map = <String, dynamic>{};
    map['province'] = province;
    map['city'] = city;
    return map;
  }
}